

 <?php
$apikey = '42B145010653DDA1E77C1D0A1C5362AF'; // put your API key here
$steamid = '76561198038792954'; // the community ID of the player to look up

$response = file_get_contents('http://api.steampowered.com/ISteamUser/GetPlayerSummaries/v0002/?key=' . $apikey . '&steamids=' . $steamid);
$json = json_decode($response, true);

$avatarurl = $json['response']['players'][0]['avatarfull']; // there's your avatar
echo '<pre>';
print_r($json);
echo '</pre><br />';
echo $avatarurl;
echo '<img src="'.$avatarurl.'" >';
?> 
